Skip to content

[codex] Preserve successful deployment status#53

Merged
mberman84 merged 1 commit into
mainfrom
codex/prefer-successful-deploy-status
Jun 23, 2026
Merged

[codex] Preserve successful deployment status#53
mberman84 merged 1 commit into
mainfrom
codex/prefer-successful-deploy-status

Conversation

@mberman84

Copy link
Copy Markdown
Contributor

What changed

  • Preserve a successful exact-main Deploy run when a later duplicate run for the same SHA is cancelled.
  • Keep genuine later deployment failures authoritative.
  • Add regressions for both cases.

Root cause

DeployBot selected the newest deployment run by creation time. GitHub dispatched the same exact-main deployment twice: the first run completed successfully, while workflow concurrency cancelled the second. The cancelled duplicate therefore replaced valid release evidence and made deploybot status --json report deploy-failed even though production had deployed successfully.

Impact

Status and release-following now treat the successful run as the durable release result only when the newer duplicate was cancelled. A later real failure still reports deploy-failed.

Validation

  • PYTHONPATH=src python3 -m unittest tests.test_pipeline.PipelineTest.test_successful_deploy_survives_later_cancelled_duplicate tests.test_pipeline.PipelineTest.test_later_failed_deploy_is_not_hidden_by_older_success
  • PYTHONPATH=src python3 -m unittest discover -s tests (270 tests)
  • ruff check .

@mberman84 mberman84 marked this pull request as ready for review June 23, 2026 00:04
@mberman84 mberman84 merged commit 7918ba2 into main Jun 23, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant